//HudView Component Constructor
function HudView(e) {
	
	//create the hud view
	var self = Ti.UI.createImageView({
  		height: e.containerheight,
  		width: e.containerwidth
	});
	
	//global listener for HUD messages
	Ti.App.addEventListener('newHUDimagejs', function(evt) {		
		Titanium.API.log("debug","new HUD image event recieved");
		self.setImage(evt.image)
	});
	
	//start the hudActivity in the comms module
	Ti.App.fireEvent('startHUD');
	
	return self;
}

//make constructor function the public component interface
module.exports = HudView;